import types from './types'
const mutations = {
  add (state) {
    state.count++
  },
  addN (state, step) {
    state.count += step
  },
  sub (state) {
    if (state.count > 0) {
      state.count--
    }
  },
  subN (state, step) {
    if (state.count > 0) {
      state.count -= step
    }
  }
}
export default mutations
